package itheima;

public class Demo8 {
    public static void main(String[] args) {
        int[] arr = {66,999,22};
        System.out.println("min = " + getMin(arr));
    }

    public static int getMin(int[] arr) {
        int min = arr[0];
        for (int i = 0; i < arr.length; i++) {
            if (arr[i] > min) {
                min = arr[i];
            }
        }
        return min;
    }
}

